//
//  @ Project : Galaxy Star Trading System
//  @ File Name : TickData.cpp
//  @ Date : 2014/9/5
//  @ Author :
//
//

#include "../StdInc.h"

namespace GSTrader
{
	namespace TradeBase
	{
		CTickData::CTickData() : m_strInstrumentID(""), m_strInstrumentName(""), m_strTradingDay(""), m_strUpdateTime(""), m_strExchangeID(""), m_dPrice(0),
			m_nVolume(0), m_dAmount(0), m_nLastUpdateProviderId(-1), m_nInstrumentID(-1), m_nUpdateMillisec(0), m_tTime(0)
		{

		}

		CTickData::~CTickData()
		{

		}

		time_t CTickData::GetTime()
		{
			return m_tTime;
		}

		CTimePoint CTickData::GetTimePoint()
		{
			time_t tmUpdate = ConvertTime(m_strActionDay, m_strUpdateTime);
			CTimePoint t1;
			t1.SetTime(tmUpdate, m_nUpdateMillisec);
			return t1;
		}
	}
}